<?php
abstract class MagicList
{
	private $_list = array();

	public function __get($var)
	{
		if (isset($this->_list[$var]))
		{
			return $this->_list[$var];
		}
		return NULL;
	}

	public function __set($var, $val)
	{
		$this->_list[$var] = $val;
	}

	public function __isset($var)
	{
		return isset($this->_list[$var]);
	}

	public function __unset($var)
	{
		unset($this->_list[$var]);
	}
}